package com.sysmanage.permissions.model;

import java.io.Serializable;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
import javax.persistence.Table;

/** 
  * @ClassName: Department 
  * @Description: 部门实体类
  * @author XXXX@163.com
  * @date 2011-9-26 上午10:02:29 
  *  
  */
@Entity
@Table(name = "C_DEPARTMENT")
public class Department implements Serializable {
	
	
	private String deptName;
	
	private Integer id;
	private Integer companyId;
	
	private String orderId;
	private Integer parentId;
	
	private Integer status;
	
	
	@Column(name="DEPT_NAME",length=30)
	public String getDeptName() {
		return deptName;
	}
	public void setDeptName(String deptName) {
		this.deptName = deptName;
	}

	@Column(name="COMPANY_ID")
	public Integer getCompanyId() {
		return companyId;
	}
	public void setCompanyId(Integer companyId) {
		this.companyId = companyId;
	}
	@Id
	@GeneratedValue(strategy=GenerationType.AUTO)
	@Column(name="DEPT_ID",nullable=false,unique=true)
	public Integer getId() {
		return id;
	}
	@Column(name="orderid")
	public String getOrderId() {
		return orderId;
	}
	@Column(name="parent_id")
	public Integer getParentId() {
		return parentId;
	}
	@Column(name="status")
	public Integer getStatus() {
		return status;
	}
	public void setId(Integer id) {
		this.id = id;
	}
	public void setOrderId(String orderId) {
		this.orderId = orderId;
	}
	public void setParentId(Integer parentId) {
		this.parentId = parentId;
	}
	public void setStatus(Integer status) {
		this.status = status;
	}
	public String toString()
	{
		return "部门[id:"+this.getId()+",name:"+this.getDeptName()+"]";
	}	
}
